﻿<div class="top-row pl-4 navbar navbar-dark">
    <a class="navbar-brand" href="">Blazor Wasm</a>
    <button class="navbar-toggler" @onclick="ToggleNavMenu">
        <span class="navbar-toggler-icon"></span>
    </button>
</div>

<div class="@NavMenuCssClass" @onclick="ToggleNavMenu">
    <ul class="nav flex-column">
        <li class="nav-item px-3">
            <NavLink class="nav-link" href="" Match="NavLinkMatch.All">
                <span class="oi oi-home" aria-hidden="true"></span> Home
            </NavLink>
            <NavLink class="nav-link" href="custom" Match="NavLinkMatch.All">
                <span class="oi oi-eye" aria-hidden="true"></span> Styling
            </NavLink>
            <NavLink class="nav-link" href="closebutton" Match="NavLinkMatch.All">
                <span class="oi oi-x" aria-hidden="true"></span> Close button
            </NavLink>
            <NavLink class="nav-link" href="backgroundcancel" Match="NavLinkMatch.All">
                <span class="oi oi-browser" aria-hidden="true"></span> Background click
            </NavLink>
            <NavLink class="nav-link" href="position" Match="NavLinkMatch.All">
                <span class="oi oi-grid-three-up" aria-hidden="true"></span> Position
            </NavLink>
            <NavLink class="nav-link" href="multiplemodals" Match="NavLinkMatch.All">
                <span class="oi oi-layers" aria-hidden="true"></span> Multiple Modals
            </NavLink>
            <NavLink class="nav-link" href="passingdata" Match="NavLinkMatch.All">
                <span class="oi oi-loop-square" aria-hidden="true"></span> Passing Data
            </NavLink>
            <NavLink class="nav-link" href="returningdata" Match="NavLinkMatch.All">
                <span class="oi oi-loop-square" aria-hidden="true"></span> Returning Data
            </NavLink>
            <NavLink class="nav-link" href="longrunningtask" Match="NavLinkMatch.All">
                <span class="oi oi-loop-circular" aria-hidden="true"></span> Long running task
            </NavLink>
            <NavLink class="nav-link" href="animation" Match="NavLinkMatch.All">
                <span class="oi oi-aperture" aria-hidden="true"></span> Animation
            </NavLink>
            <NavLink class="nav-link" href="customlayout" Match="NavLinkMatch.All">
                <span class="oi oi-eye" aria-hidden="true"></span> Custom Layout
            </NavLink>
            <NavLink class="nav-link" href="scrollablecontent" Match="NavLinkMatch.All">
                <span class="oi oi-resize-height" aria-hidden="true"></span> Scrollable Content
            </NavLink>
            <NavLink class="nav-link" href="navigateAway" Match="NavLinkMatch.All">
                <span class="oi oi-external-link" aria-hidden="true"></span> Navigate away
            </NavLink>
            <NavLink class="nav-link" href="customoverlay" Match="NavLinkMatch.All">
                <span class="oi oi-eye" aria-hidden="true"></span> Custom Overlay
            </NavLink>
        </li>
    </ul>
</div>

@code {
    bool collapseNavMenu = true;

    string NavMenuCssClass => collapseNavMenu ? "collapse" : null;

    private void ToggleNavMenu()
    {
        collapseNavMenu = !collapseNavMenu;
    }
}
